package com.liao.member.feign;

import com.liao.common.utils.Result;
import com.liao.member.config.FeignConfig;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestPart;
import org.springframework.web.multipart.MultipartFile;


/**
 * @Author: ljt
 * @Description: 上传文件到minio
 * @DateTime: 2025/3/14 上午10:25
 **/
@FeignClient(value = "youyoumall-media", configuration = FeignConfig.class)
public interface MediaFeignService {
    @PostMapping(value = "oss/upload", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
    Result<String> upload(@RequestPart("file") MultipartFile file);
}
